﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Nage.Algorithms.Solution
{
    /// <summary>
    /// Solution factory interface.
    /// When implemented, it provides methods for creating a new solution
    /// </summary>
    /// <typeparam name="TSol">Type of the solution</typeparam>
    public interface ISolutionFactory<TSol> where TSol : ISolution
    {
        /// <summary>
        /// Creates an empty solution
        /// </summary>
        /// <returns></returns>
        TSol CreateEmptySolution();

        /// <summary>
        /// Creates an initialized solution
        /// </summary>
        /// <returns></returns>
        TSol CreateInitializedSolution();

        /// <summary>
        /// Clones the solution
        /// </summary>
        /// <param name="source">source solution</param>
        /// <returns>copied solution</returns>
        TSol Copy(TSol source);
    }
}
